-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Simplified some code #1
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Generally great for me, but maybe we should remove all the comments explaining the changes.
@@ -130,8 +134,7 @@ def api_mac_post(): | |||
return '["false","unknown"]' | |||
|
|||
try: | |||
conn = psycopg2.connect(database="sunhaobomac", user="postgres", password="postgres", host="127.0.0.1", | |||
port="5432") | |||
conn = psycopg2.connect(database="sunhaobomac", user="postgre", password="postgre", host="127.0.0.1", port="5432") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually "postgres" is the default username and password for PostgreSQL so maybe we should leave it as before since this is going public, name for the database will be fixed maybe later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I forgot this point.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your pull request. I had a glance at the code, generally great. I've been busy now. I'll run integration tests after June 30th.
Thanks for the compliment and the PR! But the details are still under discussion, I'm sure these will come up recently by @Arbusz |
|
||
app = Flask(__name__) | ||
DEBUG=True |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
debug mode should NOT be opened in production environment
Brilliant idea.
Could you briefly introduce the structure of this project?
Could you create a config file for database account, password, binding port, etc.?